// vite.config.ts
import { defineConfig, loadEnv } from "file:///D:/study/react-admin/react/node_modules/.pnpm/vite@5.4.15_@types+node@22._00a7b490fe73809a3703579dc8cfdd66/node_modules/vite/dist/node/index.js";

// vite/alias.ts
import { URL, fileURLToPath } from "node:url";
var __vite_injected_original_import_meta_url = "file:///D:/study/react-admin/react/vite/alias.ts";
var alias = {
  "@": fileURLToPath(new URL("../src", __vite_injected_original_import_meta_url))
};
var alias_default = alias;

// vite/plugins/index.ts
import react from "file:///D:/study/react-admin/react/node_modules/.pnpm/@vitejs+plugin-react@4.3.4__f53fe7e259487c5ec4c12d9ce9ff9bf7/node_modules/@vitejs/plugin-react/dist/index.mjs";
import UnoCSS from "file:///D:/study/react-admin/react/node_modules/.pnpm/unocss@0.58.9_postcss@5.2.1_cdc3abe54b9b51bcac70e85ce6c4da66/node_modules/unocss/dist/vite.mjs";

// vite/plugins/mock.ts
import { viteMockServe } from "file:///D:/study/react-admin/react/node_modules/.pnpm/vite-plugin-mock@3.0.2_esbu_80256fa63fdcb57522a9f1c56c2fdda9/node_modules/vite-plugin-mock/dist/index.mjs";
function setupMock(isBuild) {
  return viteMockServe({
    mockPath: "src/mock"
    // mock文件夹路径
  });
}

// vite/plugins/auto-import.ts
import AutoImport from "file:///D:/study/react-admin/react/node_modules/.pnpm/unplugin-auto-import@19.1.2/node_modules/unplugin-auto-import/dist/vite.js";
import AntdResolver from "file:///D:/study/react-admin/react/node_modules/.pnpm/unplugin-antd-resolver@0.0.2_rollup@4.37.0/node_modules/unplugin-antd-resolver/dist/index.mjs";
import IconsResolver from "file:///D:/study/react-admin/react/node_modules/.pnpm/unplugin-icons@22.1.0_@vue+compiler-sfc@3.5.13/node_modules/unplugin-icons/dist/resolver.js";
function setupAutoImport() {
  return AutoImport({
    resolvers: [AntdResolver(), IconsResolver()],
    imports: [
      "react",
      "react-router-dom",
      {
        "react-i18next": ["initReactI18next", "useTranslation"]
      }
    ],
    dirs: ["src/components/**"],
    // 自动导入src/components目录下的所有文件
    dts: "types/auto-imports.d.ts"
  });
}

// vite/plugins/svg-icon.ts
import path from "node:path";
import { createSvgIconsPlugin } from "file:///D:/study/react-admin/react/node_modules/.pnpm/vite-plugin-svg-icons@2.0.1_fa89fa6b9b910f1b30921be26f8f154f/node_modules/vite-plugin-svg-icons/dist/index.mjs";
function setupSvgIcon(isBuild) {
  return createSvgIconsPlugin({
    iconDirs: [path.resolve(process.cwd(), "src/assets/icons/")],
    symbolId: "icon-[dir]-[name]",
    svgoOptions: isBuild
  });
}

// vite/plugins/icon.ts
import Icons from "file:///D:/study/react-admin/react/node_modules/.pnpm/unplugin-icons@22.1.0_@vue+compiler-sfc@3.5.13/node_modules/unplugin-icons/dist/vite.js";
function setupIcons() {
  return Icons({
    autoInstall: true,
    compiler: "jsx",
    jsx: "react",
    scale: 1,
    defaultStyle: `
      vertical-align: -0.15em;
      fill: currentcolor;
      overflow: hidden;
    `
  });
}

// vite/plugins/compression.ts
import compression from "file:///D:/study/react-admin/react/node_modules/.pnpm/vite-plugin-compression@0.5_67eb710f82c1048634a0f3bdbc1f9ce9/node_modules/vite-plugin-compression/dist/index.mjs";
function setupCompression(viteEnv) {
  const { VITE_BUILD_COMPRESS } = viteEnv;
  const plugin = [];
  const compressList = VITE_BUILD_COMPRESS.split(",");
  if (compressList.includes("gzip")) {
    plugin.push(
      compression({
        ext: ".gz",
        deleteOriginFile: false
      })
    );
  }
  if (compressList.includes("brotli")) {
    plugin.push(
      compression({
        ext: ".br",
        algorithm: "brotliCompress",
        deleteOriginFile: false
      })
    );
  }
  return plugin;
}

// vite/plugins/index.ts
function setupVitePlugins(viteEnv, mode, isBuild) {
  const { VITE_BUILD_COMPRESS } = viteEnv;
  const plugins = [react(), UnoCSS()];
  plugins.push(setupAutoImport());
  plugins.push(setupIcons());
  plugins.push(setupSvgIcon(isBuild));
  if (isBuild) {
    const compressList = VITE_BUILD_COMPRESS.split(",");
    if (compressList.includes("gzip") || compressList.includes("brotli"))
      plugins.push(...setupCompression(viteEnv));
  }
  if (mode === "mock") plugins.push(setupMock(isBuild));
  return plugins;
}

// vite.config.ts
var vite_config_default = defineConfig(({ command, mode }) => {
  const env = loadEnv(mode, process.cwd());
  const drop = [];
  if (env.VITE_BUILD_DROP_CONSOLE === "true") drop.push("console");
  if (env.VITE_BUILD_DROP_DEBUGGER === "true") drop.push("debugger");
  return {
    resolve: {
      alias: alias_default
    },
    plugins: setupVitePlugins(env, mode, command === "build"),
    base: "./",
    server: {
      port: 9999,
      host: "0.0.0.0",
      proxy: {
        "/proxy": {
          target: env.VITE_APP_API_BASEURL,
          changeOrigin: command === "serve" && env.VITE_OPEN_PROXY === "true",
          rewrite: (path2) => path2.replace(/\/proxy/, "")
        }
      }
    },
    build: {
      outDir: mode === "production" ? "dist" : `dist-${mode}`,
      assetsDir: "assets",
      sourcemap: env.VITE_BUILD_SOURCEMAP === "true",
      esbuild: {
        drop
      },
      chunkSizeWarningLimit: 1500,
      rollupOptions: {
        output: {
          chunkFileNames: "assets/js/[name]-[hash].js",
          entryFileNames: "assets/js/[name]-[hash].js",
          assetFileNames: "assets/[ext]/[name]-[hash].[ext]"
        }
      }
    }
  };
});
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiLCAidml0ZS9hbGlhcy50cyIsICJ2aXRlL3BsdWdpbnMvaW5kZXgudHMiLCAidml0ZS9wbHVnaW5zL21vY2sudHMiLCAidml0ZS9wbHVnaW5zL2F1dG8taW1wb3J0LnRzIiwgInZpdGUvcGx1Z2lucy9zdmctaWNvbi50cyIsICJ2aXRlL3BsdWdpbnMvaWNvbi50cyIsICJ2aXRlL3BsdWdpbnMvY29tcHJlc3Npb24udHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCJEOlxcXFxzdHVkeVxcXFxyZWFjdC1hZG1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